package demo3;

/**
 * Author：毕龙
 * Date: 2024/5/12 11:28
 */
public class TestStringInteger {
    public static void main(String[] args) {
        Integer i1 = 121;
        String st = i1.toString();
        System.out.println(st);
        //将字符串作为参数转化为int
        Integer i2 = new Integer(st);
        System.out.println(i2);


        Character c1 = Character.valueOf('A');
        Character c2 = 123;
        System.out.println(c1 == c2);

        Character c3 = 255;
        Character c4 = 255;
        System.out.println(c3 == c4);



        //如果字符串中的内容含有其他的内容 那会出现数字转化异常
        //NumberFormatException异常
        Integer hello = new Integer("hello");
        System.out.println(hello);




    }
}
